import 'package:flutter/material.dart';

class MyListViewTwo extends StatelessWidget {
  const MyListViewTwo({super.key});

  @override
  Widget build(BuildContext context) {
    return ListView.builder(
      itemCount: 10,
      itemBuilder: (context, index) {
        return _listItem();
      },
    );
  }

  Widget _listItem() {
    return Container(
      height: 80,
      padding: const EdgeInsets.all(10),
      child: Row(
        children: [
          Image.network(
            'https://yanxuan-item.nosdn.127.net/a09de222ed32efa8ffe359b1d5780574.jpg',
            width: 80,
            height: 80,
          ),
          const Expanded(
            child: Text(
              '茶水分离杯耐热隔热玻璃杯 茶水分离杯耐热隔热玻璃杯茶水分离杯耐热',
              maxLines: 2,
              overflow: TextOverflow.ellipsis,
            ),
          ),
          const Icon(
            Icons.arrow_forward_ios,
            color: Colors.grey,
            size: 18,
          ),
        ],
      ),
    );
  }
}
